From: kfraser@localhost.localdomain Date: Wed, 29 Aug 2007 13:57:12 +0000 (+0100) Subject: hvm: Intercept reads of MSR_IA32_MCG_CAP and return 0. X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~14987^2~53 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https:/%22bookmarks:///%22http:/www.example.com/cgi/%22https:/%22bookmarks:/?a=commitdiff_plain;h=fa505361f6a80ae310701fd42adadf768216dbfb;p=xen.git hvm: Intercept reads of MSR_IA32_MCG_CAP and return 0. This indicates no machine check "units", which agrees more closely with Xen's super-minimal machine check architecture (just enough to allow Windows to run). This fixes a bug that occurs when migrating a RHEL4-64bit guest to a host with fewer machine check units than the original host. These host physical details shouldn't be leaking through to guests. Signed-off-by: David Lively --- diff --git a/xen/arch/x86/hvm/svm/svm.c b/xen/arch/x86/hvm/svm/svm.c index 597f976a41..46cefe2591 100644 --- a/xen/arch/x86/hvm/svm/svm.c +++ b/xen/arch/x86/hvm/svm/svm.c @@ -1876,6 +1876,7 @@ static void svm_do_msr_access( svm_inject_exception(v, TRAP_gp_fault, 1, 0); break; + case MSR_IA32_MCG_CAP: case MSR_IA32_MCG_STATUS: case MSR_IA32_MC0_STATUS: case MSR_K8_MC1_STATUS: diff --git a/xen/arch/x86/hvm/vmx/vmx.c b/xen/arch/x86/hvm/vmx/vmx.c index 4309b3d9df..0dd069ab2e 100644 --- a/xen/arch/x86/hvm/vmx/vmx.c +++ b/xen/arch/x86/hvm/vmx/vmx.c @@ -2314,6 +2314,7 @@ static int vmx_do_msr_read(struct cpu_user_regs *regs) break; case MSR_IA32_VMX_BASIC...MSR_IA32_VMX_PROCBASED_CTLS2: goto gp_fault; + case MSR_IA32_MCG_CAP: case MSR_IA32_MCG_STATUS: case MSR_IA32_MC0_STATUS: case MSR_K8_MC1_STATUS: